ENV["RAILS_ENV"] = "test"
require File.expand_path('../../config/environment', __FILE__)
require 'rails/test_help'
#require "authlogic/test_case"

class ActiveSupport::TestCase
  
  # Setup all fixtures in test/fixtures/*.(yml|csv) for all tests in alphabetical order.
  #
  # Note: You'll currently still have to declare fixtures explicitly in integration tests
  # -- they do not yet inherit this setting
  fixtures :all
  
  
  # removed this because it doesn't work for integration tests.
  # the current_user method of ApplicationController is
  # overwritten instead (see below)
=begin
  setup :activate_authlogic
  setup :login
  def login
    UserSession.create(users(:samuel))
  end
=end
  
  # Add more helper methods to be used by all tests here...
end

class ApplicationController
  def current_user
    User.find_by_gpn(343490)
  end
end